#!/bin/bash

input=$1
nfs_rootfs_path="/home/zh/nfs/rootfs"
project_name=test_program

if [ "$input" == "clean" ]; then
    rm -rv ./build/*
else
    echo "build"
    cd build/
    cmake ..
    make -j16

    if [ $? -eq 0 ]; then
        echo "命令执行成功"
	    chmod +x ./bin/$project_name
        cp -afv ./bin/$project_name $nfs_rootfs_path/root
    else
        echo "命令执行失败"
    fi
fi













